package com.rongzhe.house.ui.fragment;

import com.rongzhe.house.presenter.BasePresenter;
import com.rongzhe.house.ui.FilterChangeListener;

/**
 * Created by huang on 2017/12/4.
 */

public abstract class FilterFragment extends BaseFragment {
    private FilterChangeListener mFilterChangeListener;

    public void setFilterChangeListener(FilterChangeListener filterChangeListener) {
        this.mFilterChangeListener = filterChangeListener;
    }
    @Override
    protected BasePresenter createPresenter() {
        return null;
    }

    protected void finishFragment() {
        if (mFilterChangeListener != null) {
            mFilterChangeListener.onFilterChanged();
        }
        getActivity().onBackPressed();
    }
}
